package com.example.permissionservice.service;

import com.example.permissionservice.dao.ResourceMapper;
import com.example.permissionservice.pojo.Resource;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class PermissionService {

    @Autowired
    ResourceMapper resourceMapper;

    public List<Resource> getResByUserID(Integer user_id){
        return resourceMapper.getByUserID(user_id);
    }

    public List<Resource> getByUsername(String username){
        return resourceMapper.getByUsername(username);
    }
}
